<%inherit file="index_base.html"/>

<%block name="subsubmain">

<div id="forum-catalog-index">
  <div class="row-fluid">
    % for INDEX, C in enumerate(CATALOG_LIST):
% if INDEX % 2:
    <div class="span6 catalog-item">
% else:
    <div class="span6 catalog-item first">
% endif
      <div class="row-fluid">
        <div class="span5 text-center">
          <a href="${ reverse_url('forum:catalog') }?id=${ C.id }">
            <div class="logo"><img src="${ C.logourl }" /></div>
            <div class="name">${ C.name }</div>
          </a>
        </div>
        <div class="span7">
          <div class="catalog-statistics">
            <div>${ _("Topics") } <span>${ C.topic_total }</span></div>
          </div>
          <div class="summary muted">${ C.summary }</div>
          % if C.managers:
          <p>
            ${ _("Moderators") }
            % for U in C.managers:
            <a href="${ reverse_url('user:view') }?id=${ U.id }">${ U.nickname }</a>
            % endfor
          </p>
          % endif
          % if can_add_topic(C):
          <p><a class="btn" href="${ reverse_url('forum:topic:add') }?cid=${ C.id }"><i class="icon-plus"></i> ${ _("New Topic") }</a></p>
          % endif
        </div>
      </div>
    </div>

    % if INDEX % 2:
  </div>
  <hr/>
  <div class="row-fluid">
    % endif

    % endfor
  </div>
</div>

<script type="text/javascript">
  just_active_myself('.index-tabs .tab-catalogs');
</script>

</%block>
